package com.turing.data.scripts.contract.transfer

import com.turing.data.vo.out.review.DependParamsVO
import com.turing.data.vo.out.review.TaskElementVO


/*
建仓期
* */

class WarehouseBuildingPeriod_30196_10_transfer {


    static List< TaskElementVO.DrawResultVO > doConvert(List< TaskElementVO.DrawResultVO > resultVOs, DependParamsVO dependParams){

        if (resultVOs!=null && resultVOs.size()>0){
            for (int i = 0; i < resultVOs.size(); i++) {
                def childTaskSn = resultVOs.get(i).childTaskSn
                if(null == childTaskSn || childTaskSn == ""){
                    continue
                }
                String modelValue = resultVOs.get(i).getText()

                if (modelValue != null && modelValue != "") {

                    String a = ""
                    char[] c = modelValue.getChars()
                    for (int j = 0; j < c.length; j++) {
                        if (c[j].isDigit()) {
                            a+=c[j]
                        }
                    }
                    resultVOs.get(i).setBusinessValue(a)
                    resultVOs.get(i).setType(1)
                }else {
                    resultVOs.get(i).setBusinessValue(modelValue)
                    resultVOs.get(i).setType(1)
                }
            }
        }

        return resultVOs
    }



}
